﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using WPFEdit.Document.ViewModels;

namespace WPFEdit.Document
{
    public class DocumentEventArgs : EventArgs
    {
        public readonly OpenDocumentInfo DocumentInfo;

        public DocumentEventArgs(OpenDocumentInfo doc)
        {
            DocumentInfo = doc;
        }

    }
    
    public delegate void DocumentEventHandler(object sender, DocumentEventArgs e);

    public class ValueChangedEventArgs<T> : EventArgs
    {
        public readonly T NewValue;
        public readonly T OldValue;

        public ValueChangedEventArgs(T oldValue, T newValue)
        {
            NewValue = newValue;
            OldValue = oldValue;
        }
    }

    public delegate void ValueChangedEventHandler<T>(object sender, ValueChangedEventArgs<T> e);
}
